<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
	<meta charset="UTF-8">
	<title>员工</title>
	<link rel="stylesheet" href="/js/plugin/layui-v2.3.0/layui/css/layui.css">
	<link rel="stylesheet" href="/css/reset.css">
	<link rel="stylesheet" href="/css/index.css">
	<link rel="stylesheet" href="/css/employee_details.css">
	<script src="/js/jquery-2.1.1.min.js"></script>
	<script src="/js/plugin/layui/layui.js"></script>
</head>
<body>
	<div class="kb-out-box">
		<div class="kb-content">
			<nav class="nav-member f-left">
				<header>
					<div class="member-img">
						<img th:if="${user.sysAttachmentPortrait!=null}" th:src="|${user.sysAttachmentPortrait.filePath}${user.sysAttachmentPortrait.id}${user.sysAttachmentPortrait.fileType}|" style="width: 90px; height: 90px; border-radius: 100px;">
						<span th:if="${user.sysAttachmentPortrait==null}" class="dotted" style="transform: translateY(0);width: 90px; height: 90px; background-color: rgb(218, 96, 104); font-size: 46px; line-height: 99px; font-family:Lantinghei SC; color: rgba(255, 255, 255, 0.9); text-align: center; border-radius: 50px;" th:text="${user.userName.substring(0,1)}"></span>
					</div>
				</header>
				<div class="kb-section">
					<ul>
						<li><span class="section-title" style="width: auto;">登录名:</span><span class="section-title-content" th:text="${user.userid}"></span></li>
						<li><span class="section-title" style="width: auto;">姓名:</span><span class="section-title-content" th:text="${user.userName}"></span></li>
						<li><span class="section-title" style="width: auto;">性别:</span><span class="section-title-content" th:text="${user.userSex==1}?男:女"></span></li>
						<li><span class="section-title" style="width: auto;">电话:</span><span class="section-title-content" th:text="${user.phoneNumber}"></span></li>
						<li><span class="section-title" style="width: auto;">微信号:</span><span class="section-title-content" th:text="${user.wechat}"></span></li>
						<li><span class="section-title" style="width: auto;">邮箱:</span><span class="section-title-content" style="width: 120px;" th:text="${user.emailAddress}"></span></li>
						<li><span class="section-title" style="width: auto;">职位:</span><span class="section-title-content" th:text="${user.post}"></span></li>
					</ul>
				</div>
			</nav>
			<section class="nav-section-container f-right">
				<header class="nav-header clear-fix">
					<div class="nav-header-title">
						<h2 class='header-title' th:text="${user.userName}"></h2>
					</div>
				</header>
				<div class="nav-section-content-container">
					<!-- 用户信息列表 -->
					<table class="content-table table-align">
						<thead>
							<tr><th style="width: 100px;">上级员工</th><th>下级员工</th><th>模块权限</th><th>分店</th></tr>
						</thead>
						<tbody>
							<tr class="border-none">
								<td>
									<a class="a-hover" href="javascript:void(0)" onclick="detai(this)" th:if="${SuperiorUser!=null}" th:text="${SuperiorUser.userName}" th:id="${SuperiorUser.id}">范穗文</a>
								</td>
								<td>
									<div style="margin-bottom: 5px;" th:each="users : ${xiaUsers}"><a class="a-hover" href="javascript:void(0)" th:id="${users.id}" onclick="detai(this)" th:text="${users.User_Name}"></a></div>
								</td>
								<td>
									<div style="margin-bottom: 5px;"></div><div style="margin-bottom: 5px;">员工管理</div>
									<div style="margin-bottom: 5px;"></div><div style="margin-bottom: 5px;">报修管理</div>
									<div style="margin-bottom: 5px;">财务管理</div>
								</td>
								<td>
									<div style="margin-bottom: 5px;" th:each="team : ${teams}" >
										<span style="margin-right: 10px;" th:text="${team.project}?${team.project.projectName}:''"></span>
										<span th:if="${team.teamRole=='1'}" >(负责人)</span>
										<span th:if="${team.teamRole=='2'}" >(运营人员)</span>
										<span th:if="${team.teamRole=='3'}" >(财务人员)</span>
										<span th:if="${team.teamRole=='4'}" >(核销人员)</span>
										<span th:if="${team.teamRole=='5'}" >(确认核销人员)</span>
										<span th:if="${team.teamRole=='6'}" >(观察人员)</span>
										<span th:if="${team.teamRole=='7'}" >(报修负责人)</span>
										<span th:if="${team.teamRole=='8'}" >(合同审批人)</span>
									</div>
									</div>
								</td>
							</tr>
						</tbody>
					</table>
					
				</div>
			</section>
		</div>
	</div>
</body>
<script>	
$(function(){
layui.use(['table','layer'], function(){
	var table = layui.table,layer=layui.layer;
	//方法级渲染
	
 });
})
function detai(obj){
	parent.location.hash='#employeeDetials/'+obj.id;
	parent.getHash()
}
</script>
</html>